﻿using ETL.Business.Handlers.ProjectUserHandler;
using ETL.Business.Models;
using WebMatrix.WebData;

namespace ETL.Web.CustomCredential
{
    public class ETLCredential
    {
        public static string UserId
        {
            get { return WebSecurity.CurrentUserName; }
        }

        public static string UserFullName
        {
            get
            {
                ProjectUserModel model = (new GetUserById()).Execute(WebSecurity.CurrentUserName);
                if (model != null)
                    return model.FirstName + " " + model.SurName;
                else return string.Empty;
            }
        }

        
    }
}